package com.moonshineproject.plugin.settings.vo
{
    import com.moonshineproject.plugin.settings.renderers.PluginRenderer;
    import mx.core.IVisualElement;

    public class PluginSetting extends AbstractSetting
    {
        protected var _value:String ="";

        [Bindable]
        public var author:String;

        [Bindable]
        public var description:String;

        public function PluginSetting(pluginName:String, author:String, description:String, activated:Boolean)
        {
            this.name = pluginName;
            this.label = "activated";
            this.author = author;
            this.description = description;
            stringValue = defaultValue= String(activated);
        }

		override protected function getSetting():*{
			return _value;
		}
		
		override protected function setPendingSetting(v:*) : void{
			super.setPendingSetting(v);
			_value = v;
		}
		
        override public function get renderer():IVisualElement
        {
            var rdr:PluginRenderer = new PluginRenderer();
            rdr.setting = this;
            return rdr;
        }

    }
}